<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            width: 30px;
            height: 30px;
            background-color: blueviolet;
            line-height: 20px;
            text-align: center;
            border-radius: 100%;
            position: absolute;
        }
    </style>
</head>
<body>
    <script>
        var divs = []
        for (var i = 0; i < 200; i++) {
            var div = document.createElement('div')
            div.className = 'box'
            div.innerHTML = i
            divs.push(div)
            document.body.appendChild(div)
        } 
        console.log(divs) 
        document.onmousemove = function (e) {
            e = e || window.event
            for (var i = divs.length - 1 ; i > 0; i--) {
                divs[i].style.left = divs[i-1].style.left
                divs[i].style.top = divs[i-1].style.top
            }
            divs[0].style.left = e.clientX + 'px'
            divs[0].style.top = e.clientY + 'px'
        } 
    </script>
</body>
</html>